package com.bango.blackberry;

final class BangoPoster implements Runnable
{

	private BangoAgent _bangoAgent;
	private boolean _postCurrent;
	BangoPoster(BangoAgent bangoAngent, boolean postCurrent)
	{
		super();
		_bangoAgent = bangoAngent;
		_postCurrent = postCurrent;
	}

	public final void run()
	{
		_bangoAgent.bangoLogger.PostStoredEvents();

		if(_postCurrent)
		{
			_bangoAgent.bangoLogger.PostEvents();
		}
	}

}